namespace UniversalAdminSystem.Domian.FileStorage.ValueObjects;

public record FilePath
{
    public string Value { get; }
    private FilePath(string value)
    {
        if (string.IsNullOrWhiteSpace(value))
            throw new ArgumentException("文件路径不能为空");
        if (value.Length > 500)
            throw new ArgumentException("文件路径不能超过500字符");
        Value = value;
    }
    public static FilePath Create(string value) => new(value);
    public static implicit operator string(FilePath path) => path.Value;
} 